package com.jt.demo6;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;


@Configuration
@ComponentScan("com.jt.demo6")
public class SpringCofig {

    //自己手动创建对象,交给spring容器管理
    @Bean
    public  User user(){
        return  new User();
    }
}
